<div class="airPreloading">
    <el-form  label-width="100%">
        <el-form-item label="">
        </el-form-item>
    </el-form>
     <div class="panel-parent">
        <div class="self">
            <el-form :inline="true" ref="form" :model="form" label-position="right" label-width="40px" >
                <el-form-item label="从"  v-if="$route.params.type!='today'">
                    <el-date-picker
                            v-model="form.startDate"
                            type="date"
                            placeholder="开始日期"
                            value-format="yyyy-MM-dd"
                    >
                    </el-date-picker>
                </el-form-item>
                <el-form-item label="到" v-if="$route.params.type!='today'">
                    <el-date-picker
                            v-model="form.endDate"
                            type="date"
                            placeholder="结束日期"
                            value-format="yyyy-MM-dd"
                    >
                    </el-date-picker>
                </el-form-item>
                <el-form-item label=" ">
                <el-select v-model="form.flightNum" filterable placeholder="航班号" clearable
                           @change="handleSelect">
                    <el-option
                            v-for="plane in planes"
                            :key="plane.flightInfoId"
                            :label="plane.flightNum"
                            :value="plane"
                    >
                    </el-option>
                </el-select>
                </el-form-item>
                <el-form-item label=" "  class = "transparent">
                    <el-button type="primary" @click="queryFlightPlane">查询</el-button>
                </el-form-item>
            </el-form>
            <kf-table
                    border
                    :data="tableData"
                    ref="flightPlane"
                    page-size="10"
                      stripe  :title="title" top="20px">
                <el-table-column prop="flightInfo.flightNum"  label="航班号"  min-width="100">
                </el-table-column>
                <el-table-column  prop="flightInfo.flightType" label="机型" min-width="100" >
                </el-table-column>
                <el-table-column prop="importOrExport" label="进出港" min-width="80">
                </el-table-column>
                <el-table-column  label="预约航线" min-width="150" prop="originating">
                    <template scope="scope">{{scope.row.originating+"-"+scope.row.destination}}</template>
                </el-table-column>
                <el-table-column prop="industryLoadPo.precheckNum" label="预检人数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.adultNum" label="成人数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.childrenNum" label="儿童数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.babyNum" label="婴儿数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.unattendedNum" label="无陪数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.wheelchairNum" label="轮椅数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.other" label="其它" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.totalPeople" label="总人数" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.cargoWeight" label="货物重量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.mailWeight" label="邮件重量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.baggageWeight" label="行李重量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.courierNumber" label="快递数量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.largeCargoNum" label="超大货物数量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.totalBaggageNum" label="行李数量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.animalNum" label="动物数量" width="80">
                </el-table-column>
                <el-table-column prop="industryLoadPo.loadingDate" label="配载日期" width="150">
                </el-table-column>
                <el-table-column label="操作" fixed="right" width="180" >
                    <template scope="scope" >
                        <el-button type="text" @click="planLoad(scope)"><span style=" color: #51a6ea">配载</span></el-button>

                        <el-button type="text" @click="planLoadedDetails(scope)"><span style=" color: #51a6ea" >配载详情</span></el-button>
                    </template>
                </el-table-column>



                <template slot="editForm">
                  <el-form :inline="true" :model="stowageFormInline"  ref="stowageFormInline" class="stowage-form-inline" :rules="rules">
                                <el-row>
                                    <el-col :span="8">
                                        <el-form-item label="预检人数"  prop="precheckNum" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.precheckNum" class="input-width">
                                            </el-input> 人
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="成人数"  prop="adultNum"  label-width="100px">
                                            <el-input v-model.number="stowageFormInline.adultNum" class="input-width">
                                            </el-input> 人
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="儿童数"  prop="childrenNum" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.childrenNum" class="input-width">
                                            </el-input> 人
                                        </el-form-item>
                                    </el-col>
                                </el-row>
                                    <el-row>

                                    <el-col :span="8">
                                        <el-form-item label="婴儿数"  prop="babyNum" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.babyNum" class="input-width">
                                            </el-input> 人
                                        </el-form-item>
                                    </el-col>
                                        <el-col :span="8">
                                            <el-form-item label="无陪数"  prop="unattendedNum" label-width="100px">
                                                <el-input v-model.number="stowageFormInline.unattendedNum"class="input-width">
                                                </el-input> 人
                                            </el-form-item>
                                        </el-col>
                                        <el-col :span="8">
                                            <el-form-item label="轮椅数"  prop="wheelchairNum" label-width="100px">
                                                <el-input v-model.number="stowageFormInline.wheelchairNum" class="input-width">
                                                </el-input> 人
                                            </el-form-item>
                                        </el-col>
                                </el-row>

                                <el-row>
                                    <el-col :span="8">
                                        <el-form-item label="其它人数"  prop="other" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.other" class="input-width">
                                            </el-input> 人
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="总人数"  prop="totalPeople" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.totalPeople" class="input-width">
                                            </el-input> 人
                                        </el-form-item>
                                    </el-col>

                                    <el-col :span="8">
                                        <el-form-item label="货物重量"  prop="cargoWeight" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.cargoWeight" class="input-width">
                                            </el-input> kg
                                        </el-form-item>
                                    </el-col>
                                </el-row>

                                <el-row>
                                    <el-col :span="8">
                                        <el-form-item label="邮件重量"  prop="mailWeight" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.mailWeight" class="input-width">
                                            </el-input> kg
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="行李重量"  prop="baggageWeight" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.baggageWeight" class="input-width">
                                            </el-input> kg
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="快递数"  prop="courierNumber" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.courierNumber" class="input-width">
                                            </el-input> 件
                                        </el-form-item>
                                    </el-col>
                                </el-row>
                                <el-row>
                                    <el-col :span="8">
                                        <el-form-item label="超大物数量"  prop="largeCargoNum" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.largeCargoNum" class="input-width">
                                            </el-input> 件
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="行李数量"  prop="totalBaggageNum" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.totalBaggageNum" class="input-width">
                                            </el-input> 件
                                        </el-form-item>
                                    </el-col>
                                    <el-col :span="8">
                                        <el-form-item label="动物数量"  prop="animalNum" label-width="100px">
                                            <el-input v-model.number="stowageFormInline.animalNum" class="input-width">
                                            </el-input> 个
                                        </el-form-item>
                                    </el-col>
                                </el-row>
                                    <el-row>
                                    <el-col :span="12">
                                        <el-form-item label="配载日期"  prop="loadingDate" label-width="100px">
                                            <el-date-picker
                                                    v-model="stowageFormInline.loadingDate"
                                                    align="right"
                                                    type="date"
                                                    placeholder="请选择日期"
                                                    value-format="yyyy-MM-dd"
                                                    style="width: 150px">
                                            </el-date-picker>
                                        </el-form-item>
                                    </el-col>
                                </el-row>
                            </el-form>
                         </template>
                <template slot="formBtn">
                    <el-button  @click="clear()">取 消</el-button>
                    <el-button type="primary" @click="save()">确定保存</el-button>
                </template>
            </kf-table>


            <!--模态框：配载单-->
            <el-dialog :visible.sync="dialogFormVisible1" top="5px" title="配载详情">
                    <el-form :inline="true" :model="stowageFormInline"  ref="stowageFormInline" class="stowage-form-inline">
                        <el-row>
                            <el-col :span="12">
                                <el-form-item label="航班号"  prop="flightNum">
                                    <el-input v-model="flightInfo.flightNum" class="input-width"></el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                            <el-col :span="8">
                                <el-form-item label="出发站"prop="originating" label-width="120px">
                                    <el-input v-model="originating" class="input-width"></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item  label="到达站" prop="destination" label-width="120px">
                                    <el-input v-model="destination" class="input-width"></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item  label="飞机类型"prop="flightKind" label-width="120px">
                                    <el-input v-model="flightInfo.flightKind" class="input-width" >
                                    </el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                            <el-col :span="8">
                                <el-form-item label="预检人数"  prop="precheckNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.precheckNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="成人数"  prop="adultNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.adultNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="荷载人数"  prop="loadNumber" label-width="120px">
                                    <el-input v-model.number="flightInfo.loadNumber" class="input-width" ></el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                            <el-col :span="8">
                                <el-form-item label="儿童数"  prop="childrenNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.childrenNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="婴儿数"  prop="babyNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.babyNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="无陪数"  prop="unattendedNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.unattendedNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                            <el-col :span="8">
                                <el-form-item label="轮椅数"  prop="wheelchairNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.wheelchairNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="其它"  prop="other" label-width="120px">
                                    <el-input v-model="stowageFormInline.other"class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="总人数"  prop="totalPeople" label-width="120px">
                                    <el-input v-model="stowageFormInline.totalPeople" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                        <el-col :span="8">
                            <el-form-item label="货物重量"  prop="cargoWeight" label-width="120px">
                                <el-input v-model="stowageFormInline.cargoWeight" class="input-width">
                                </el-input>
                            </el-form-item>
                        </el-col>
                        <el-col :span="8">
                            <el-form-item label="邮件重量"  prop="mailWeight" label-width="120px">
                                <el-input v-model="stowageFormInline.mailWeight" class="input-width">
                                </el-input>
                            </el-form-item>
                        </el-col>
                            <el-col :span="8">
                                <el-form-item label="行李重量"  prop="baggageWeight" label-width="120px">
                                    <el-input v-model="stowageFormInline.baggageWeight" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                    </el-row>
                        <el-row>
                            <el-col :span="8">
                                <el-form-item label="快递数"  prop="courierNumber" label-width="120px">
                                    <el-input v-model="stowageFormInline.courierNumber" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="超大物数量"  prop="largeCargoNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.largeCargoNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="行李数量"  prop="totalBaggageNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.totalBaggageNum"  class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                            <el-col :span="8">
                                <el-form-item label="动物数量"  prop="animalNum" label-width="120px">
                                    <el-input v-model="stowageFormInline.animalNum" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="8">
                                <el-form-item label="配载日期"  prop="loadingDate" label-width="120px">
                                    <el-input v-model="stowageFormInline.loadingDate" class="input-width">
                                    </el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
<el-row style="margin: 10px;padding-bottom: 30px;text-align: center" >
    <el-button type="text" @click="see">查看飞机基础信息</el-button>
</el-row>
                        <div v-if="isee">
                        <el-row>
                            <el-col :span="12">
                                <el-form-item label="机型"  prop="flightType" label-width="120px">
                                    <el-input v-model="flightInfo.flightType"class="input-width" ></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="12">
                            <el-form-item label="空机重量"  prop="emptyWeight" label-width="120px">
                                <el-input v-model.number="flightInfo.emptyWeight" class="input-width"></el-input>
                            </el-form-item>
                            </el-col>
                        </el-row>

                        <el-row>
                            <el-col :span="12">
                                <el-form-item label="最大油箱容量"  prop="maximumTankCapacity" label-width="120px">
                                    <el-input v-model="flightInfo.maximumTankCapacity"></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="12">
                                <el-form-item label="最大起飞总重"  prop="maximumTakeOffWeight" label-width="120px">
                                    <el-input v-model="flightInfo.maximumTakeOffWeight"></el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>

                        <el-row>
                            <el-col :span="12">
                                <el-form-item label="最大着陆重量"  prop="maximumLandingWeight" label-width="120px">
                                    <el-input v-model="flightInfo.maximumLandingWeight"></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="12">
                                <el-form-item label="最大零燃油重量"  prop="maximumZeroFuelWeight" label-width="120px">
                                    <el-input v-model="flightInfo.maximumZeroFuelWeight"></el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        <el-row>
                            <el-col :span="12">
                                <el-form-item label="最大滑出前重量"  prop="maximumSlipBeforeWeight" label-width="120px">
                                    <el-input v-model="flightInfo.maximumSlipBeforeWeight"></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="12">
                                <el-form-item label="最大商务载重"  prop="maximumBusinessLoad" label-width="120px">
                                    <el-input v-model="flightInfo.maximumBusinessLoad"></el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>

                        <el-row>
                            <el-col :span="12">
                                <el-form-item label="内仓承载重量" prop="bearingWeightOfInnerSilo" label-width="120px">
                                    <el-input v-model="flightInfo.bearingWeightOfInnerSilo"></el-input>
                                </el-form-item>
                            </el-col>
                            <el-col :span="12">
                                <el-form-item label="外仓承载重量" prop="outerBinWeight" label-width="120px">
                                    <el-input v-model="flightInfo.outerBinWeight"></el-input>
                                </el-form-item>
                            </el-col>
                        </el-row>
                        </div>
                    </el-form>
            </el-dialog>


        </div>

    </div>
</div>